//
//  MagzineTableViewCell.m
//  TextApplication
//
//  Created by dllo on 16/8/30.
//  Copyright © 2016年 yh. All rights reserved.
//

#import "MagzineTableViewCell.h"
#import "TAMacro.h"

@implementation MagzineTableViewCell

- (instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier {
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        _picImageView = [[UIImageView alloc] init];
        [self.contentView addSubview:self.picImageView];

        _titleLabel = [[UILabel alloc] init];
        [self.contentView addSubview:self.titleLabel];

        _typeLabel = [[UILabel alloc] init];
        [self.contentView addSubview:self.typeLabel];
    }
    return self;
}

- (void)layoutSubviews {
    [super layoutSubviews];
    _picImageView.frame = self.contentView.bounds;
    _picImageView.backgroundColor = [UIColor grayColor];
    _titleLabel.frame = CGRectMake(0, CONTENTHEIGHT / 2 - 15, CONTENTWIDTH, 30);
    _titleLabel.textColor = [UIColor whiteColor];
    _titleLabel.font = [UIFont systemFontOfSize:14];
    _titleLabel.textAlignment = 1;
    _typeLabel.frame = CGRectMake(0, CONTENTHEIGHT / 2 + 15, CONTENTWIDTH, 20);
    _typeLabel.textAlignment = 1;
    _typeLabel.textColor = [UIColor whiteColor];
    _typeLabel.font = [UIFont systemFontOfSize:14];

}



- (void)awakeFromNib {
    // Initialization code
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

@end
